package com.jf3q.sup.controller;

import com.jf3q.sup.domain.Menus;
import com.jf3q.sup.service.MenusService;
import com.jf3q.sup.vo.ResultVo;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;

@RestController
@RequestMapping("/menu")
public class MenuController {
    @Autowired
    MenusService menusService;

    @GetMapping("/getMenu")
    public ResultVo getMenu() {
        List<Menus> menus = menusService.getMenu();
        return ResultVo.success("",menus);
    }
}
